find where line has horizontal tangent